import Mock from 'mockjs';

let url = '/api/home'
//设置mock数据请求的时间
Mock.setup({
    timeout: 400
})
Mock.mock(url, {
    "code": 200,
    "data": {
        "records|10": [
            {
                "imgUrl": Mock.Random.image('155x155'),
                "description": Mock.Random.cparagraph(1), //随机生成字符串
                "id": Mock.mock('@id'), //随机生成id
                "name": Mock.Random.ctitle(5), //随机生成title
            }
        ]
    }
});